home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Turnbull China Bikeride
/
Turnbull China Bikeride - Disc 2.iso
/
STUTTGART
/
COMM
/
BBS
/
RISCBBS
/
NewTo101
< prev
next >
Wrap
Text File
|
1992-02-25
|
5KB
|
130 lines
This file lists the major things that are new/different to v1.01/beta.
The v1.01/beta release does not add any really new 'outward' features, but
is a kind of efficiency-maintenance update... it does away with the old,
cumbersome way the menu-system worked.
* New menu-structures.
RiscBBS no longer has all menus inside the SysBBS file, there's now a
new subdir called Menus which holds a 'menu-file' per menu. The advantages
of the system are obvious: textually named menus are easier to find and
maintain.
* New method of defining menu-options.
The old 'option' command has been completely thrown out and is replaced by
the much more powerful 'defopt' command. I know this change is quite
radical and will ask quite a bit of time to reconfigure, but once it's up
and running, it's really very powerful!!
The syntax of 'defopt' is best illustrated with the following example:
defopt N= `Logoff note` 10 ``
m_enter `A1 S`
logoff
endopt
The first 3 parameters of 'defopt' are the same as those found with the old
'option' command: 'N=' specifies which key to assign (here, it's key 'N').
The string `Logoff note` tells RiscBBS to display "Logoff note" when this
option is selected, the 10 is the user-level needed to access this option,
and finnally, the 4th (new) parameter is a string specifying which userkeys
the user should have to access this option. Here, no userkeys are needed, so
an empty string is given.
Then comes a number of commands that must be executed when the option is
selected. Any command valid in bbs-files is valid here! Herein lies the real
power of the new 'defopt' method.
Finally, 'endopt' marks the end of the option-definition.
* Default options feature.
It's now possible to set up a file called System.Kernel.Defaults in which you
put definitions of menu-options you want to have active on all menus. They
are set up in exactly the same way as a normal 'local' menu-option.
Local option-definitions will override default option-definitions when they
are encountered.
* New/modified commands.
Some commands have been added/changed to cope with the new menu system:
Command Example usage
------- -------------
msgbase msgbase <path> Messages Will define the messagebase path and
messagebase name. (only in SysBBS)
filebase filebase <path> Files See above.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
base base M Msgbase.Main Will select the messagebase and make
menu Msgbase.Main the active one.
menu menu Filebase.NewScan Will make menu Filebase.NewScan the
active one.
pushmenu pushmenu Will push the currently active menu
on the menu stack. This stack can
hold max. 16 menus.
popmenu popmenu Pops the last pushed menu from the
menu stack.
a_list a_list F Will list all accessible areas in the
filebase.
a_change a_change M Allows the user to change the active
area in the messagebase.
* Return codes.
Most of RiscBBS's commands now return an 'error-code' through the new 'RET'
bbs-variable. Succesful termination will set RET to 0. When an error
occured during execution of a command, the value of RET will be set
accordingly. I will provide a list of possible RETurn codes when I release
the docs, but for now it is suffice to check whether RET is 0 or not.
An example of using RET:
defopt G= `Globally` 10 ``
a_reset `A0 B G`
f_list `1 G N L`
if RET=0
menu Filebase.GlobZipNew
else
menu Filebase.Main
endif
endopt
* New/enhanced control constructs.
RiscBBS now provides some quite powerful control constructs that allow for
a flexible bbs-setup.
- The if-else-endif construct:
Doesn't need any comments really, except that they may be nested up to 32
levels deep.
- The do-enddo construct.
This is a disguised while loop: 'do' (like 'if') accepts a single string
that is to be evaluated. As long as it evaluates to a non-0 value, the loop
will execute. Maximum nesting-level is 8.
- The alt-case-endalt construct.
This a powerful one: it acts like a C switch construct but has less
restrictions: 'alt' accepts a single string which is to be evaluated.
Multiple 'case' statements can then be used to examine this value. A 'case'
may be broken using 'skip' (cfr: C's break), fallthru is also supported.
The default 'case' is denoted using 'case any'. 'endalt' closes an 'alt'
construct. Note that specifying 'alt select' at the top of the construct
restricts you to evaluate boolean expressions only, but looks a bit neater
than 'alt -1' (TRUE = -1, FALSE = 0). Maximum nesting-level is 4.
* Discouraging goto's.
The new control constructs should be used in preference to goto's/labels.
Goto's that jump out of another control construct do not reset the nesting
level and thus can upset the bbs-script interpreter when used repeatedly.
Carl Declerck.